import { HarmonyPilotCommentCollection } from "./HarmonyPilotCommentCollection";
import * as vscode from "vscode";

/**
 * Enum for comment collection types
 */
export enum CommentCollectionType {
  /**
   * AI review comments
   */
  AI_REVIEW = "AI-Review"
}


export class CommentCollectionFactory {
    private map: Map<CommentCollectionType, HarmonyPilotCommentCollection>;

    constructor(
        private readonly context: vscode.ExtensionContext,
    ) {
        this.map = new Map();
    }

  public createCommentCollection(type: CommentCollectionType): HarmonyPilotCommentCollection {
    const commentCollection = new HarmonyPilotCommentCollection(type, this.context, type);
    this.map.set(type, commentCollection);
    return commentCollection;
  }

  public getCommentCollection(type: CommentCollectionType): HarmonyPilotCommentCollection|undefined {
    return this.map.get(type);
  }
}
